let routes = [{
        path: '/',
        title: '首页',
        component: () =>
            import ('../src/view/layout.vue'),
        redirect: {
            path: 'index',
        },
        children: [{
                path: 'index',
                component: () =>
                    import ('../src/view/index.vue'),
            },
            {
                //全部商品
                path: 'all',
                component: () =>
                    import ('../src/view/all.vue'),
            },
            {   //关于我们
                path: 'about',
                component: () =>
                    import ('../src/view/about.vue'),
            },
            {   
                path: 'order',
                component: () =>
                    import ('../src/view/order.vue'),
            },
            {
                path: 'collect',
                component: () =>
                    import ('../src/view/collect.vue'),
            },
            {
                path: 'shoppingCart',
                component: () =>
                    import ('../src/view/shoppingCart.vue'),
            },
            {
                path: 'particulars',
                component: () =>
                    import ('../src/view/particulars.vue'),
            },
            {
                path: 'joinShoppingCart',
                component: () =>
                    import ('../src/view/joinShoppingCart.vue'),
            },
            {
                path: 'text',
                component: () =>
                    import ('../src/view/text.vue'),
            },
            {
                path: 'createOrder',
                component: () =>
                    import ('../src/view/createOrder.vue'),
            },
        ],
    },
    {
        path: '/checkout',
        component: () =>
            import ('../src/view/checkout.vue'),
    },
]

export default routes